package com.woniuxy.service;

import com.woniuxy.dao.AccountDao;
import com.woniuxy.entity.Account;

public class AccountService {
    /**
     * 注册方法
     * @param account
     */
    public void regiestAccount(Account account) {
        AccountDao accountDao = new AccountDao();
        accountDao.regiestAccount(account);
    }

    /**
     * 这个方法用来判断账号是否重复
     * @return
     */
    public int regiestCheckNumber(Account account){
        AccountDao accountDao = new AccountDao();
       return accountDao.regiestCheckNumber(account);
    }

    public void login(String username, String password) {
        AccountDao accountDao = new AccountDao();
        accountDao.login(username, password);
    }
}
